<template>
    <div class="aa" ref="bb">

    </div>
</template>

<script setup>
import * as echarts from 'echarts'
import {ref,defineProps,onMounted,watch} from 'vue'
const {ww1}=defineProps(['ww1'])
let bb=ref()
let myChart
onMounted(()=>{
    myChart = echarts.init(bb.value);
    myChart.setOption(ww1)
})
watch(ww1,()=>{
    myChart.setOption(ww1)
})

</script>

<style lang="scss" scoped>
.aa{
    width: 500px;
    height: 500px;
}

</style>